package com.prtek.reminder.util;

import java.io.IOException;
import java.io.InputStream;

/**
 * Created by jarly on 2018/11/30.
 */

public class IoUtil {

  public static String inputStreamToString(InputStream inputStream) {
    try {
      byte[] bytes = new byte[inputStream.available()];
      inputStream.read(bytes, 0, bytes.length);
      String json = new String(bytes);
      return json;
    } catch (IOException e) {
      return null;
    }
  }
}
